// background.js
chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
  if (request.type === 'GET_RESOURCE_URL') {
    const { path } = request;
    const url = chrome.runtime.getURL(path);
    sendResponse({ url });
  }
});